---
title: Kalshi
description: Access prediction markets and trade on Kalshi
---

import { BlockInfoCard } from "@/components/ui/block-info-card"

<BlockInfoCard 
  type="kalshi"
  color="#09C285"
/>

{/* MANUAL-CONTENT-START:intro */}
[Kalshi](https://kalshi.com) is a federally regulated exchange where users can trade directly on the outcomes of future events—prediction markets. Kalshi’s robust API and Sim integration enable agents and workflows to programmatically access all aspects of the platform, supporting everything from research and analytics to automated trading and monitoring.

With Kalshi’s integration in Sim, you can:

- **Market & Event Data:** Search, filter, and retrieve real-time and historical data for markets and events; fetch granular details on market status, series, event groupings, and more.
- **Account & Balance Management:** Access account balances, available funds, and monitor real-time open positions.
- **Order & Trade Management:** Place new orders, cancel existing ones, view open orders, retrieve a live orderbook, and access complete trade histories.
- **Execution Analysis:** Fetch recent trades, historical fills, and candlestick data for backtesting or market structure research.
- **Monitoring:** Check exchange-wide or series-level status, receive real-time updates about market changes or trading halts, and automate responses.
- **Automation Ready:** Build end-to-end automated agents and dashboards that consume, analyze, and trade on real-world event probabilities.

By using these unified tools and endpoints, you can seamlessly incorporate Kalshi’s prediction markets, live trading capabilities, and deep event data into your AI-powered applications, dashboards, and workflows—enabling sophisticated, automated decision-making tied to real-world outcomes.
{/* MANUAL-CONTENT-END */}


## Usage Instructions

Integrate Kalshi prediction markets into the workflow. Can get markets, market, events, event, balance, positions, orders, orderbook, trades, candlesticks, fills, series, exchange status, and place/cancel/amend trades.



## Tools

### `kalshi_get_markets`

Retrieve a list of prediction markets from Kalshi with optional filtering

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `status` | string | No | Filter by status \(unopened, open, closed, settled\) |
| `seriesTicker` | string | No | Filter by series ticker |
| `eventTicker` | string | No | Filter by event ticker |
| `limit` | string | No | Number of results \(1-1000, default: 100\) |
| `cursor` | string | No | Pagination cursor for next page |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Markets data and metadata |

### `kalshi_get_market`

Retrieve details of a specific prediction market by ticker

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `ticker` | string | Yes | The market ticker \(e.g., "KXBTC-24DEC31"\) |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Market data and metadata |

### `kalshi_get_events`

Retrieve a list of events from Kalshi with optional filtering

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `status` | string | No | Filter by status \(open, closed, settled\) |
| `seriesTicker` | string | No | Filter by series ticker |
| `withNestedMarkets` | string | No | Include nested markets in response \(true/false\) |
| `limit` | string | No | Number of results \(1-200, default: 200\) |
| `cursor` | string | No | Pagination cursor for next page |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Events data and metadata |

### `kalshi_get_event`

Retrieve details of a specific event by ticker

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `eventTicker` | string | Yes | The event ticker |
| `withNestedMarkets` | string | No | Include nested markets in response \(true/false\) |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Event data and metadata |

### `kalshi_get_balance`

Retrieve your account balance and portfolio value from Kalshi

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Balance data and metadata |

### `kalshi_get_positions`

Retrieve your open positions from Kalshi

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `ticker` | string | No | Filter by market ticker |
| `eventTicker` | string | No | Filter by event ticker \(max 10 comma-separated\) |
| `settlementStatus` | string | No | Filter by settlement status \(all, unsettled, settled\). Default: unsettled |
| `limit` | string | No | Number of results \(1-1000, default: 100\) |
| `cursor` | string | No | Pagination cursor for next page |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Positions data and metadata |

### `kalshi_get_orders`

Retrieve your orders from Kalshi with optional filtering

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `ticker` | string | No | Filter by market ticker |
| `eventTicker` | string | No | Filter by event ticker \(max 10 comma-separated\) |
| `status` | string | No | Filter by status \(resting, canceled, executed\) |
| `limit` | string | No | Number of results \(1-200, default: 100\) |
| `cursor` | string | No | Pagination cursor for next page |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Orders data and metadata |

### `kalshi_get_order`

Retrieve details of a specific order by ID from Kalshi

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `orderId` | string | Yes | The order ID to retrieve |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Order data |

### `kalshi_get_orderbook`

Retrieve the orderbook (yes and no bids) for a specific market

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `ticker` | string | Yes | Market ticker \(e.g., KXBTC-24DEC31\) |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Orderbook data and metadata |

### `kalshi_get_trades`

Retrieve recent trades across all markets

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `limit` | string | No | Number of results \(1-1000, default: 100\) |
| `cursor` | string | No | Pagination cursor for next page |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Trades data and metadata |

### `kalshi_get_candlesticks`

Retrieve OHLC candlestick data for a specific market

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `seriesTicker` | string | Yes | Series ticker |
| `ticker` | string | Yes | Market ticker \(e.g., KXBTC-24DEC31\) |
| `startTs` | number | Yes | Start timestamp \(Unix seconds\) |
| `endTs` | number | Yes | End timestamp \(Unix seconds\) |
| `periodInterval` | number | Yes | Period interval: 1 \(1min\), 60 \(1hour\), or 1440 \(1day\) |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Candlestick data and metadata |

### `kalshi_get_fills`

Retrieve your portfolio

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `ticker` | string | No | Filter by market ticker |
| `orderId` | string | No | Filter by order ID |
| `minTs` | number | No | Minimum timestamp \(Unix milliseconds\) |
| `maxTs` | number | No | Maximum timestamp \(Unix milliseconds\) |
| `limit` | string | No | Number of results \(1-1000, default: 100\) |
| `cursor` | string | No | Pagination cursor for next page |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Fills data and metadata |

### `kalshi_get_series_by_ticker`

Retrieve details of a specific market series by ticker

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `seriesTicker` | string | Yes | Series ticker |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Series data and metadata |

### `kalshi_get_exchange_status`

Retrieve the current status of the Kalshi exchange (trading and exchange activity)

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Exchange status data and metadata |

### `kalshi_create_order`

Create a new order on a Kalshi prediction market

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `ticker` | string | Yes | Market ticker \(e.g., KXBTC-24DEC31\) |
| `side` | string | Yes | Side of the order: 'yes' or 'no' |
| `action` | string | Yes | Action type: 'buy' or 'sell' |
| `count` | string | Yes | Number of contracts \(minimum 1\) |
| `type` | string | No | Order type: 'limit' or 'market' \(default: limit\) |
| `yesPrice` | string | No | Yes price in cents \(1-99\) |
| `noPrice` | string | No | No price in cents \(1-99\) |
| `yesPriceDollars` | string | No | Yes price in dollars \(e.g., "0.56"\) |
| `noPriceDollars` | string | No | No price in dollars \(e.g., "0.56"\) |
| `clientOrderId` | string | No | Custom order identifier |
| `expirationTs` | string | No | Unix timestamp for order expiration |
| `timeInForce` | string | No | Time in force: 'fill_or_kill', 'good_till_canceled', 'immediate_or_cancel' |
| `buyMaxCost` | string | No | Maximum cost in cents \(auto-enables fill_or_kill\) |
| `postOnly` | string | No | Set to 'true' for maker-only orders |
| `reduceOnly` | string | No | Set to 'true' for position reduction only |
| `selfTradePreventionType` | string | No | Self-trade prevention: 'taker_at_cross' or 'maker' |
| `orderGroupId` | string | No | Associated order group ID |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Created order data |

### `kalshi_cancel_order`

Cancel an existing order on Kalshi

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `orderId` | string | Yes | The order ID to cancel |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Canceled order data |

### `kalshi_amend_order`

Modify the price or quantity of an existing order on Kalshi

#### Input

| Parameter | Type | Required | Description |
| --------- | ---- | -------- | ----------- |
| `keyId` | string | Yes | Your Kalshi API Key ID |
| `privateKey` | string | Yes | Your RSA Private Key \(PEM format\) |
| `orderId` | string | Yes | The order ID to amend |
| `ticker` | string | Yes | Market ticker |
| `side` | string | Yes | Side of the order: 'yes' or 'no' |
| `action` | string | Yes | Action type: 'buy' or 'sell' |
| `clientOrderId` | string | Yes | The original client-specified order ID |
| `updatedClientOrderId` | string | Yes | The new client-specified order ID after amendment |
| `count` | string | No | Updated quantity for the order |
| `yesPrice` | string | No | Updated yes price in cents \(1-99\) |
| `noPrice` | string | No | Updated no price in cents \(1-99\) |
| `yesPriceDollars` | string | No | Updated yes price in dollars \(e.g., "0.56"\) |
| `noPriceDollars` | string | No | Updated no price in dollars \(e.g., "0.56"\) |

#### Output

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `success` | boolean | Operation success status |
| `output` | object | Amended order data |



## Notes

- Category: `tools`
- Type: `kalshi`
